﻿/*
 * 委外商产品统计DAL
 * PHJ
 */
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using Microsoft.Practices.EnterpriseLibrary.Common;
using Microsoft.Practices.EnterpriseLibrary.Data;
using System.Data;
using System.Data.Common;

namespace MINERP.DAL.Statistics
{
    public class OutShopStatDAL
    {

        public static DataSet GetProductsStat(int outShopid, DateTime startDate, DateTime endDate)
        {
            Database db = DatabaseFactory.CreateDatabase();
            DbCommand dbCommand = db.GetStoredProcCommand("GetOutPutProductAccount");
            db.AddInParameter(dbCommand, "@outshopid ", DbType.Int32, outShopid);
            db.AddInParameter(dbCommand, "@startTime", DbType.DateTime, startDate);
            db.AddInParameter(dbCommand, "@endTime", DbType.DateTime, endDate);
            return db.ExecuteDataSet(dbCommand);
        }
    }
}
